<?php
	if(!defined("IN_APP"))
	{
		exit;
	}

	include renderTemplate('index/my/apply_fanli');
	




	
	$parm = requestArrayParm($_REQUEST);
	
	$method = getParam('m','get','menu');
	
	
	
	
	if($method == 'account_number')
	{
		unset($wheres);
		$wheres['uid'] = $loginuser['id'];
		$wheres['type'] = '1';
		$zhifubao = _Account_number::getAccount_numberInfo($wheres);
		
		unset($wheres);
		$wheres['uid'] = $loginuser['id'];
		$wheres['type'] = '2';
		$yinhangka = _Account_number::getAccount_numberInfo($wheres);
		
		include renderTemplate('index/my/account_number');
	}
	
	if($method == 'apply_fanli')
	{
		unset($wheres);
		
		$list = _Tongji_log::getUserbrowseListByChanpinID($loginuser['id']);
		
		if(!empty($loginuser))
		{
			if(empty($loginuser['nickname']))
			{
				header("Location:".SITE_URL.'index.php?m=my');
				exit;
			}
			include renderTemplate('index/my/apply_fanli');
		}
		
		
	}
	
	if($method == 'fanli_record')
	{
		unset($wheres,$sort,$pages,$between);
		
		$wheres['uid'] = $loginuser['id'];
		
		//$sort['status'] = 'asc';
		
		$sort['addtime'] = 'desc';
		
		$resData = _Fanli::getFanliList($wheres, $page, $between, $sort);
		
		
		foreach ($resData  as $key => $value)
		{
			//获取产品信息
			$value['chanpin'] = _ChanPin::getChanPinInfo(array('id'=>$value['pid']));
			//获取获取项目信息
			$value['item'] = _ChanPin::getChanPin_ItemInfo(array('id'=>$value['iid']));
			
			$list[] = $value;
		}
		

		include renderTemplate('index/my/fanli');
	}
	
	
	
	